class Animal(object):

    def running(self):
        print("Animal is running")


class Dog(Animal):

    def running(self):
        print("Dog is running")

class Cat(object):

    def running(self):
        print("Cat is running")

class Stone(object):
    pass

def run_twice(animal):
    animal.running()
    animal.running()


run_twice(Animal())
run_twice(Dog())
run_twice(Cat())
# run_twice(Stone())